import unittest
import HTMLTestRunner

case_dir = './'
suite = unittest.TestLoader().discover(start_dir=case_dir,pattern='test_ddtbaidu*.py')

if __name__ == '__main__':
    fp = open('./result.html','wb')

    runner = HTMLTestRunner.HTMLTestRunner(
        stream=fp,
        title='HTMLTestRunner Example',
        description = 'This is the descripiton of the running results'
    )
    runner.run(suite)
    fp.close()